package org.example;

import java.util.concurrent.TimeUnit;
import java.util.stream.IntStream;
import lombok.SneakyThrows;
import lombok.extern.slf4j.Slf4j;

@Slf4j
public class Main {


    public static void main(String[] args) {
        IntStream.range(11, 20).forEach(i -> {
            Thread thread = new Thread(new ThreadGroup("test"),new Runnable() {
                @SneakyThrows
                @Override
                public void run() {
                    while (true) {
                        TimeUnit.MILLISECONDS.sleep(100);
                        log.info("log-test-{}-{}", i, i);
                    }
                }
            });
            thread.start();
        });
    }
}